<!--
 * @Description:简易日历
 * @Author: Sun
 * @Date: 2019-07-01 20:05:50
 * @LastEditors: Sun
 * @LastEditTime: 2019-07-01 22:12:28
 -->
<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <meta http-equiv="X-UA-Compatible" content="ie=edge">
  <title>arguments参数</title>
	<style>
		#div input.active{background: yellow;}
		#divmo{width: 200px; height: 200px;background: #F1F1F1;}
		#divmo >div{display: none; width: 100%; height: 200px;}
		#divmo >div:first-child{display: block;}
	</style>
	<script>
		window.onload = function () {
			var odiv=document.getElementById("div1")
		  function sum(){
				var result=0;
				for (let i = 0; i < arguments.length; i++) {
					result+=arguments[i]
				}
				return result
			}
		 console.log("arguments求和",sum(11,16,17))
		 
		 function css(obj,name,value){
			 if(arguments.length==2){
				 return obj.style[name]
			 }else{
				 obj.style[name]=arguments[2]
			 }
		 }
		 css(odiv,'background','green')
		  // console.log("arguments求和",sum(11,16,17))
		}
	</script>
</head>

<body>
  <div id="div1"  style="width: 200px; height: 200px; background: #DEB887;">
  	oul.children 属性用法
		parenNode 父节点
		offsetParent 获取元素在页面的实际位置
		
  </div>


</body>

</html>